package com.company.project.mapper.ldjsc.wzsj;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.company.project.entity.ldjsc.wzsj.JscIndexDictionaryEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * 指标字典
 *
 * @author wenbin
 * @email *****@mail.com
 * @date 2025-08-20 14:17:05
 */
@Mapper
public interface JscIndexDictionaryMapper extends BaseMapper<JscIndexDictionaryEntity> {

    @Select(" select t1.id,t1.tag,t1.title,t1.detail,t1.data_time,t1.index_no,t1.source,t1.depart,t1.update_time,t2.index_name from jscwz_template_explain t1\n" +
            "left join jsc_index_dictionary t2 on t1.index_no=t2.index_no\n" +
            "where t2.index_name = #{index_name} and t1.source = '省司法厅' order by t1.update_time desc")
    List<JscIndexDictionaryEntity> selectindexName(String index_name);
}
